﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;

using WcfAfvandingServiceLibrary;

namespace AfvandingSystem
{
    /// <summary>
    /// Interaction logic for OpretPumpe.xaml
    /// </summary>
    public partial class OpretPumpe : Window
    {
        IAfvandingL afvanding;

        public OpretPumpe(IAfvandingL afvanding)
        {
            InitializeComponent();
            this.afvanding = afvanding;

            lvPumpestationermedP.ItemsSource = afvanding.MinePumpestationer();
        }

        private void btnOpretPumpe_Click(object sender, RoutedEventArgs e)
        {
            double vandkapacitet = double.Parse(txtVandkapacitet.Text);
            //bool kører = cbKører.IsChecked.Value;
            Pumpestation pumpestation = ((Pumpestation)lvPumpestationermedP.SelectedItem);

           // afvanding.OpretPumpe(vandkapacitet, kører, pumpestation.PumpestationsId);
            MessageBox.Show("Pumpe oprettet.");
        }
    }
}
